package com.ctshk.rpc.order.airexpress.req;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDate;

/**
 * <p>
 * 机场快线订单表
 * </p>
 *
 * @author 叶冠峰
 * @since 2021-02-23
 */
@Data
@ApiModel(value = "AirportExpressOrderReq对象", description = "机场快线订单表")
public class AirportExpressOrderRejectPaymentReq implements Serializable {

    private static final long serialVersionUID = 1L;

    @NotNull(message = "机场快线产品ID不能为空")
    @ApiModelProperty(value = "机场快线产品id", required = true)
    private Long airportExpressId;

    @NotEmpty(message = "票种名称不能为空")
    @ApiModelProperty(value = "票种名称")
    private String ticketTypeName;

    @NotNull(message = "有效时间不能为空,yyyy-MM-dd")
    @ApiModelProperty(value = "有效时间", required = true)
    private LocalDate effectiveTime;

    @NotNull(message = "购买数量不能为空")
    @ApiModelProperty(value = "购买数量")
    private Integer number;

    @NotNull(message = "成人票数必须大于等于1")
    @Range(min = 1, max = 20, message = "成人票数必须大于等于1")
    @ApiModelProperty(value = "成人票数", required = true)
    private Integer adultTicketNumber;

    @NotNull(message = "小童票数必须大于等于0")
    @Range(min = 0, max = 20, message = "小童票数必须大于等于0")
    @ApiModelProperty(value = "小童票数")
    private Integer childrenTicketNumber;

    @NotNull(message = "是否代理不能为空，1:代理,2:非代理")
    @Range(min = 1, max = 2, message = "是否代理值域，1:代理,2:非代理")
    @ApiModelProperty(value = "是否代理")
    private Integer isAgent;

    @ApiModelProperty(value = "代理公司id")
    private Long agencyId;

    @ApiModelProperty(value = "代理公司")
    private String agencyCompany;

    @ApiModelProperty(value = "代理人名称")
    private String agentUserName;

    @NotNull(message = "产品类型不能为空")
    @ApiModelProperty(value = "产品类型，枚举ProductType")
    private Integer productType;

    @NotNull(message = "来源不能为空")
    @ApiModelProperty(value = "来源,枚举OrderSource")
    private Integer source;

    @ApiModelProperty(value = "销售人员id")
    private Long salesmanId;

    @ApiModelProperty(value = "销售人员名称")
    private String salesmanName;

    @NotBlank(message = "联系人姓不能为空")
    @ApiModelProperty(value = "联系人姓", required = true)
    private String surname;

    @NotBlank(message = "联系人名不能为空")
    @ApiModelProperty(value = "联系人名", required = true)
    private String name;

    @ApiModelProperty(value = "联系人姓名")
    private String contactName;

    @NotBlank(message = "联系人手机不能为空")
    @ApiModelProperty(value = "联系人手机", required = true)
    private String contactMobile;

    @NotNull(message = "联系人手机区号不能为空")
    @ApiModelProperty(value = "联系人手机区号id", required = true)
    private Long contactMobileAreaCodeId;

    @ApiModelProperty(value = "联系人手机区号", required = true)
    private String contactMobileAreaCode;

    @ApiModelProperty(value = "联系人国籍ID", required = true)
    private String contactCountryId;

    @ApiModelProperty(value = "联系人国籍", required = true)
    private String contactCountryName;

    @ApiModelProperty(value = "联系人邮箱")
    private String contactEmail;

    @Range(min = 1, max = 2, message = "会员查询类型(1:手机号查询,2:证件号码查询,null:不使用会员)")
    @ApiModelProperty(value = "会员查询类型(1:手机号查询,2:证件号码查询)")
    private Integer memberQueryType;

    @ApiModelProperty(value = "会员查询证件类型(根据CRM提供的证件类型列表)")
    private Integer memberQueryCertificatesType;

    @ApiModelProperty(value = "会员查询编码(根据memberQueryType判断)")
    private String memberQueryCode;

    @ApiModelProperty(value = "使用积分")
    private Integer usingPoints;

    @ApiModelProperty(value = "优惠卷id")
    private Long couponId;

    @ApiModelProperty(value = "备注")
    private String remark;

//    @NotNull(message = "称谓不能为空(1:先生,2:女士,3:小姐)")
//    @Range(min = 1,max = 3, message = "称谓不正确(1:先生,2:女士,3:小姐)")
//    @ApiModelProperty(value = "联系人称谓，枚举TouristType(1:先生,2:女士,3:小姐)")
//    private Integer contactTitle;

    @NotNull(message = "称谓不能为空(1:先生,2:女士,3:小姐)")
    @Range(min = 1, max = 3, message = "称谓不正确(1:先生,2:女士,3:小姐)")
    @ApiModelProperty(value = "联系人称谓，枚举TouristType(1:先生,2:女士,3:小姐)")
    private Integer gender;

    @ApiModelProperty(value = "销售方式(1：单品销售 2：打包销售)")
    private Integer salesMethods;

    /* 需求变更，去掉旅客列表
    @Valid
    @NotEmpty(message = "旅客列表不能为空")
    @ApiModelProperty(value = "旅客列表")
    private List<AirportExpressOrderTouristReq> airportExpressOrderTouristList;*/
}
